package com.flyme.module.base.client.api;


import com.flyme.common.core.model.ResultBody;
import com.flyme.common.core.model.query.PagerInfo;
import com.flyme.module.base.client.entity.SysConfig;
import com.flyme.module.base.client.entity.SysDictData;
import org.springframework.web.bind.annotation.*;

import java.util.List;

/**
 * @author zyf
 */
@RequestMapping("/dictdata")
public interface SysDictDataRemoteService{

    @PostMapping(value="/list")
    ResultBody list(@ModelAttribute PagerInfo pagerInfo, @ModelAttribute SysDictData dictData);

    @GetMapping(value="/getByType/{type}")
    ResultBody<Object> getByType(@PathVariable String type);

    @PostMapping(value="/add")
    public ResultBody<Object> add(@ModelAttribute SysDictData dictData);

    @PostMapping(value="/edit")
    public ResultBody<Object> edit(@ModelAttribute SysDictData dictData);

    @DeleteMapping(value="/delByIds/{ids}")
    public ResultBody<Object> delByIds(@PathVariable Long[] ids);

    @GetMapping(value="/getConfigByType/{type}")
    ResultBody<Object> getConfigByType(@PathVariable String type);

    @PostMapping(value="/saveEditIosRait")
    ResultBody<Object> saveEditIosRait(@ModelAttribute SysConfig config);

    @PostMapping(value="/saveEditShareRatio")
    ResultBody<Object> saveEditShareRatio(@RequestParam String shareRatio);

    @PostMapping(value="/saveEditUpOrDownRatio")
    ResultBody<Object> saveEditUpOrDownRatio(@RequestParam String upOrDown);

    @PostMapping(value="/getOssSeting")
    ResultBody getOssSeting();
}
